package library.model;

import com.gooddies.reflection.fieldprocessing.fieldextractors.jdbcExctractor.JdbcField;

/**
 * @author Dmitry
 */
public class BooksAuthorPojo {
    @JdbcField(field = "id")
    private int id;
    @JdbcField(field = "book")
    private String bookName;
    @JdbcField(field = "author")
    private String author;
    @JdbcField(field = "description")
    private String description;

    public BooksAuthorPojo(String bookName, String author) {
        this.bookName = bookName;
        this.author = author;
    }

    public BooksAuthorPojo() {
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String desription) {
        this.description = desription;
    }

    public boolean hasDescription() {
        if (description == null || description.equals("0")) {
            return false;
        }
        return true;
    }

    public String getBookName() {
        return bookName;
    }

    public String getAuthor() {
        return author;
    }

    void setBookName(String bookName) {
        this.bookName = bookName;
    }

    void setAuthor(String author) {
        this.author = author;
    }
}
